package com.kfm.service;

import com.kfm.dao.FileDao;

import java.io.File;
import java.util.Date;

/**
 * file的业务逻辑层
 */
public class FileService {

    private FileDao fileDao = new FileDao();

    public int add(String name, long size, Date createTime, String ip, String link) {
        try {
            return fileDao.insert(name, size, createTime, ip, link);
        } catch (Exception e) {
            e.printStackTrace();
            return -1;
        }
    }
}
